import request from '@/utils/request'
import {parseStrEmpty} from "@/utils/ruoyi";

// 查询入库明细单列表
export function listIbDetails(query) {
    return request({
        url: '/wms/ibDetails/list',
        method: 'get',
        params: query
    })
}

// 主明细关联入库明细单列表
export function inboundDetails(query) {
    return request({
        url: '/wms/ibMaster/details',
        method: 'get',
        params: query
    })
}

// 查询入库明细单详细
export function getIbDetails(ibDetailId) {
    return request({
        url: '/wms/ibDetails/' + parseStrEmpty(ibDetailId),
        method: 'get'
    })
}

// 新增入库明细单
export function addIbDetails(data) {
    return request({
        url: '/wms/ibDetails',
        method: 'post',
        data: data
    })
}

// 修改入库明细单
export function updateIbDetails(data) {
    return request({
        url: '/wms/ibDetails',
        method: 'put',
        data: data
    })
}

// 删除入库明细单
export function delIbDetails(ibDetailId) {
    return request({
        url: '/wms/ibDetails/' + ibDetailId,
        method: 'delete'
    })
}
